#pragma once
#include "CacheObj.h"
#include "BaseProtocol.h"
#include "ODBCBase.h"

enum
{
    BillingType_Buy_YuanBao,
	BillingType_Exchange_Money,
	BillingType_Signup,
	BillingType_Match_Award,
	BillingType_Sell_Item,
	BillingType_Buy_Item,
};

struct BillingRecord
{
	char szUserName[Max_UserName];
    DWORD dwUserId;
	int nBillingType;
	time_t tmTime;
	int nYuanBao;
	int nMoney;
	int nItemId;
	int nItemCount;
};

class CBillingObj :	public CCacheObj, public CODBCBase
{
public:
	CBillingObj(void);
	~CBillingObj(void);
public:
	virtual DWORD GetKey();
	virtual BOOL Serialize(CODBCInterface &odbcInterface);
	virtual BOOL Unserialize(CODBCInterface &odbcInterface);

	BillingRecord m_record;
};
